package com.ugoodtech.mdcc.web.dto;


import com.ugoodtech.mdcc.core.StatusConstants;
import com.ugoodtech.mdcc.core.domain.QuestionPaper;
import com.ugoodtech.mdcc.core.utils.StatusUtil;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * Copyright © 2013 All Rights Reserved, Ugood Technology, Inc.
 */
@ApiModel("问卷数据")
public class QuestionPaperResponse {
    @ApiModelProperty("编号")
    private Long paperId;
    @ApiModelProperty("创建日期")
    private String creationTime;
    @ApiModelProperty("创建原因")
    private String createReason;
    @ApiModelProperty("状态")
    private String status;


    public QuestionPaperResponse(QuestionPaper questionPaper) {
        this.paperId=questionPaper.getId();
        this.creationTime=questionPaper.getCreationTimeStr();
        this.createReason=questionPaper.getReason();
        if(null!=questionPaper.getStatus()){
            this.status=StatusUtil.getStatusStr(questionPaper.getStatus().name(), StatusConstants.STATUS_STR_LIST);
        }
    }

    public Long getPaperId() {
        return paperId;
    }

    public void setPaperId(Long paperId) {
        this.paperId = paperId;
    }

    public String getCreationTime() {
        return creationTime;
    }

    public void setCreationTime(String creationTime) {
        this.creationTime = creationTime;
    }

    public String getCreateReason() {
        return createReason;
    }

    public void setCreateReason(String createReason) {
        this.createReason = createReason;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }
}
